package leetcode.code120.Triangle;

import java.util.ArrayList;
import java.util.List;

import leetcode.IDebug;

public abstract class Triangle implements IDebug {

	abstract public int minimumTotal(List<List<Integer>> triangle);

	@Override
	public void debug1() {
		int[][] input = new int[][] { { 2 }, { 3, 4 }, { 6, 5, 7 }, { 4, 1, 8, 3 } };
		int expect = 11;
		List<List<Integer>> ll = new ArrayList<>();
		for (int[] element : input) {
			List<Integer> l = new ArrayList<>();
			for (int j = 0; j < element.length; j++) {
				l.add(element[j]);
			}
			ll.add(l);
		}
		int result = this.minimumTotal(ll);
		System.out.println(expect + " " + result);
	}

	@Override
	public void debug2() {
		// TODO Auto-generated method stub

	}

	@Override
	public void debug3() {
		// TODO Auto-generated method stub

	}

	@Override
	public void debug4() {
		// TODO Auto-generated method stub

	}

}
